﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DiagrammInternalStructure.Exceptions
{
    class VoidTypeOfParameterException: Exception
    {
        private const string PARAMETER_NAME_TAG = "<param>";
        private const string MESSAGE = "The parameter \"" + PARAMETER_NAME_TAG + "\" can not be of type void";
        public VoidTypeOfParameterException(ParameterField parameter):base(MESSAGE.Replace(PARAMETER_NAME_TAG, parameter.Name))
        { 
        
        }

        public VoidTypeOfParameterException(string name)
            : base(MESSAGE.Replace(PARAMETER_NAME_TAG, name))
        {

        }
    }
}
